Kotlin algorithm to reverse a given string

visit shbcf.ru